package controller

import (
	"context"
	"xr-game-server/core/httpserver"
	"xr-game-server/dto/taskdto"
	"xr-game-server/module/task"
)

type Task struct {
}

func initTask() {
	httpserver.RegAPI("/task", &Task{})
}
func (receiver *Task) ReceiveTaskReward(ctx context.Context, req *taskdto.ReceiveTaskRewardReq) (bool, error) {
	return task.Receive(ctx, req)
}
func (receiver *Task) GetTask(ctx context.Context, req *taskdto.GetTaskReq) ([]*taskdto.TaskDto, error) {
	return task.GetTasks(ctx, req)
}

func (receiver *Task) PushTask(ctx context.Context, req *taskdto.PushTaskReq) (*taskdto.TaskDto, error) {
	return nil, nil
}
